package JAVA_LianXi_50;

public class program_21 {
	public static void main(String[] args) {
		int sum=0;
				
		for (int i=1;i<=3;i++) {
			int ss=1;
			for (int j=1;j<=i;j++) {
				ss*=j;
			}
			sum+=ss;
		}
		
		System.out.println(sum);
	}
}
